-- --------------------------------------------------------
-- Host:                         127.0.0.1
-- Server version:               5.5.8-log - MySQL Community Server (GPL)
-- Server OS:                    Win32
-- HeidiSQL version:             7.0.0.4053
-- Date/time:                    2013-03-17 23:44:34
-- --------------------------------------------------------

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET NAMES utf8 */;
/*!40014 SET FOREIGN_KEY_CHECKS=0 */;

-- Dumping database structure for fitnessblackbook
DROP DATABASE IF EXISTS `fitnessblackbook`;
CREATE DATABASE IF NOT EXISTS `fitnessblackbook` /*!40100 DEFAULT CHARACTER SET utf8 */;
USE `fitnessblackbook`;


-- Dumping structure for table fitnessblackbook.career
DROP TABLE IF EXISTS `career`;
CREATE TABLE IF NOT EXISTS `career` (
  `id` int(10) NOT NULL AUTO_INCREMENT,
  `name` varchar(100) NOT NULL,
  `location` varchar(100) NOT NULL,
  `image` varchar(100) NOT NULL,
  `position_available` varchar(100) NOT NULL,
  `contact_person` varchar(100) NOT NULL,
  `description` varchar(500) NOT NULL,
  `salary` double NOT NULL,
  `commission` double NOT NULL,
  `share_to_social_site` tinyint(1) NOT NULL DEFAULT '0',
  `created_on` datetime NOT NULL,
  `updated_on` datetime NOT NULL,
  `created_by_id` int(10) NOT NULL,
  `updated_by_id` int(10) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.career: ~1 rows (approximately)
/*!40000 ALTER TABLE `career` DISABLE KEYS */;
INSERT INTO `career` (`id`, `name`, `location`, `image`, `position_available`, `contact_person`, `description`, `salary`, `commission`, `share_to_social_site`, `created_on`, `updated_on`, `created_by_id`, `updated_by_id`) VALUES
	(1, 'Career Name', 'Career Locaton', '', 'Career Poston', 'Contact Person', 'Descrpton											', 123, 12345, 0, '2013-03-17 17:33:22', '0000-00-00 00:00:00', 1, 0);
/*!40000 ALTER TABLE `career` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.location
DROP TABLE IF EXISTS `location`;
CREATE TABLE IF NOT EXISTS `location` (
  `id` int(10) NOT NULL AUTO_INCREMENT,
  `name` varchar(100) NOT NULL,
  `created_on` datetime NOT NULL,
  `updated_on` datetime NOT NULL,
  `created_by_id` int(10) NOT NULL,
  `updated_by_id` int(10) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=12 DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.location: ~2 rows (approximately)
/*!40000 ALTER TABLE `location` DISABLE KEYS */;
INSERT INTO `location` (`id`, `name`, `created_on`, `updated_on`, `created_by_id`, `updated_by_id`) VALUES
	(11, 'Eastern Cape', '2013-03-17 03:45:30', '0000-00-00 00:00:00', 1, 0);
/*!40000 ALTER TABLE `location` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.permission
DROP TABLE IF EXISTS `permission`;
CREATE TABLE IF NOT EXISTS `permission` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` varchar(25) NOT NULL,
  PRIMARY KEY (`id`),
  UNIQUE KEY `name` (`name`)
) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.permission: 3 rows
/*!40000 ALTER TABLE `permission` DISABLE KEYS */;
INSERT INTO `permission` (`id`, `name`) VALUES
	(1, 'administrator'),
	(2, 'developer'),
	(3, 'editor');
/*!40000 ALTER TABLE `permission` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.plugin_settings
DROP TABLE IF EXISTS `plugin_settings`;
CREATE TABLE IF NOT EXISTS `plugin_settings` (
  `plugin_id` varchar(40) NOT NULL,
  `name` varchar(40) NOT NULL,
  `value` varchar(255) NOT NULL,
  UNIQUE KEY `plugin_setting_id` (`plugin_id`,`name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.plugin_settings: 0 rows
/*!40000 ALTER TABLE `plugin_settings` DISABLE KEYS */;
/*!40000 ALTER TABLE `plugin_settings` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.processional_specialist_field
DROP TABLE IF EXISTS `processional_specialist_field`;
CREATE TABLE IF NOT EXISTS `processional_specialist_field` (
  `id` int(10) NOT NULL AUTO_INCREMENT,
  `professional_id` int(10) NOT NULL DEFAULT '0',
  `specialist_field_id` int(10) NOT NULL DEFAULT '0',
  `created_on` datetime NOT NULL,
  `updated_on` datetime NOT NULL,
  `created_by_id` int(10) NOT NULL,
  `updated_by_id` int(10) NOT NULL,
  PRIMARY KEY (`id`),
  KEY `FK_processional_specialist_field_professional` (`professional_id`),
  KEY `FK_processional_specialist_field_specialist_field` (`specialist_field_id`),
  CONSTRAINT `FK_processional_specialist_field_professional` FOREIGN KEY (`professional_id`) REFERENCES `professional` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
  CONSTRAINT `FK_processional_specialist_field_specialist_field` FOREIGN KEY (`specialist_field_id`) REFERENCES `specialist_field` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.processional_specialist_field: ~0 rows (approximately)
/*!40000 ALTER TABLE `processional_specialist_field` DISABLE KEYS */;
/*!40000 ALTER TABLE `processional_specialist_field` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.professional
DROP TABLE IF EXISTS `professional`;
CREATE TABLE IF NOT EXISTS `professional` (
  `id` int(10) NOT NULL AUTO_INCREMENT,
  `firstname` varchar(100) NOT NULL,
  `lastname` varchar(100) NOT NULL,
  `dob` date NOT NULL,
  `location` varchar(100) NOT NULL,
  `qualification` varchar(100) NOT NULL,
  `mobile` varchar(15) NOT NULL,
  `office_number` varchar(15) NOT NULL,
  `website` varchar(100) NOT NULL,
  `email` varchar(50) NOT NULL,
  `facebook_page` varchar(100) NOT NULL,
  `industry_experience` varchar(500) NOT NULL,
  `image` varchar(255) NOT NULL,
  `review` varchar(500) NOT NULL,
  `share_to_social` tinyint(4) NOT NULL DEFAULT '0',
  `created_on` datetime NOT NULL,
  `updated_on` datetime NOT NULL,
  `created_by_id` int(10) NOT NULL,
  `updated_by_id` int(10) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.professional: ~0 rows (approximately)
/*!40000 ALTER TABLE `professional` DISABLE KEYS */;
/*!40000 ALTER TABLE `professional` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.setting
DROP TABLE IF EXISTS `setting`;
CREATE TABLE IF NOT EXISTS `setting` (
  `name` varchar(40) NOT NULL,
  `value` text NOT NULL,
  UNIQUE KEY `id` (`name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.setting: 8 rows
/*!40000 ALTER TABLE `setting` DISABLE KEYS */;
INSERT INTO `setting` (`name`, `value`) VALUES
	('admin_title', 'Admin'),
	('language', 'en'),
	('theme', 'default'),
	('default_status_id', '1'),
	('default_filter_id', 'textile'),
	('default_tab', 'location'),
	('allow_html_title', 'off'),
	('plugins', 'a:4:{s:7:"textile";i:1;s:8:"markdown";i:1;s:14:"page_not_found";i:1;s:12:"file_manager";i:1;}');
/*!40000 ALTER TABLE `setting` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.specialist_field
DROP TABLE IF EXISTS `specialist_field`;
CREATE TABLE IF NOT EXISTS `specialist_field` (
  `id` int(10) NOT NULL AUTO_INCREMENT,
  `name` varchar(100) NOT NULL,
  `created_on` datetime NOT NULL,
  `updated_on` datetime NOT NULL,
  `created_by_id` int(10) NOT NULL,
  `updated_by_id` int(10) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.specialist_field: ~0 rows (approximately)
/*!40000 ALTER TABLE `specialist_field` DISABLE KEYS */;
/*!40000 ALTER TABLE `specialist_field` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.supplier
DROP TABLE IF EXISTS `supplier`;
CREATE TABLE IF NOT EXISTS `supplier` (
  `id` int(10) NOT NULL AUTO_INCREMENT,
  `name` varchar(250) NOT NULL,
  `address` varchar(250) NOT NULL,
  `mobile` varchar(15) NOT NULL,
  `office_number` varchar(15) NOT NULL,
  `email` varchar(100) NOT NULL,
  `website` varchar(100) NOT NULL,
  `facebook_page` varchar(250) NOT NULL,
  `about_us` varchar(500) NOT NULL,
  `image` varchar(100) NOT NULL,
  `picture_1` varchar(100) NOT NULL,
  `picture_2` varchar(100) NOT NULL,
  `picture_3` varchar(100) NOT NULL,
  `review` varchar(500) NOT NULL,
  `share_to_social_site` tinyint(4) NOT NULL DEFAULT '0',
  `created_on` datetime NOT NULL,
  `updated_on` datetime NOT NULL,
  `created_by_id` int(10) NOT NULL,
  `updated_by_id` int(10) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.supplier: ~2 rows (approximately)
/*!40000 ALTER TABLE `supplier` DISABLE KEYS */;
INSERT INTO `supplier` (`id`, `name`, `address`, `mobile`, `office_number`, `email`, `website`, `facebook_page`, `about_us`, `image`, `picture_1`, `picture_2`, `picture_3`, `review`, `share_to_social_site`, `created_on`, `updated_on`, `created_by_id`, `updated_by_id`) VALUES
	(3, 'Supplier Name', 'Supplier Address', '9823223355', '020-12345', 'bhosalevishal@gmail.com', 'http://vishalbhosale.com', 'http://facebook.com/vishal.g.bhosale', '																																																																																																				', '', '', '', '', '																																																																																																				', 0, '2013-03-17 16:45:14', '0000-00-00 00:00:00', 1, 0),
	(4, 'Supplier Name', 'Supplier Address', '9823223355', '020-12345', 'bhosalevishal@gmail.com', 'http://vishalbhosale.com', 'http://facebook.com/vishal.g.bhosale', '															', '', '', '', '', '															', 1, '2013-03-17 17:07:00', '0000-00-00 00:00:00', 1, 0);
/*!40000 ALTER TABLE `supplier` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.user
DROP TABLE IF EXISTS `user`;
CREATE TABLE IF NOT EXISTS `user` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `name` varchar(100) DEFAULT NULL,
  `email` varchar(255) DEFAULT NULL,
  `username` varchar(40) NOT NULL,
  `password` varchar(40) DEFAULT NULL,
  `created_on` datetime DEFAULT NULL,
  `updated_on` datetime DEFAULT NULL,
  `created_by_id` int(11) DEFAULT NULL,
  `updated_by_id` int(11) DEFAULT NULL,
  PRIMARY KEY (`id`),
  UNIQUE KEY `username` (`username`)
) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.user: 1 rows
/*!40000 ALTER TABLE `user` DISABLE KEYS */;
INSERT INTO `user` (`id`, `name`, `email`, `username`, `password`, `created_on`, `updated_on`, `created_by_id`, `updated_by_id`) VALUES
	(1, 'Administrator', 'admin@yoursite.com', 'admin', 'd033e22ae348aeb5660fc2140aec35850c4da997', '2013-03-16 18:47:36', '2013-03-15 18:47:37', 1, 1);
/*!40000 ALTER TABLE `user` ENABLE KEYS */;


-- Dumping structure for table fitnessblackbook.user_permission
DROP TABLE IF EXISTS `user_permission`;
CREATE TABLE IF NOT EXISTS `user_permission` (
  `user_id` int(11) NOT NULL,
  `permission_id` int(11) NOT NULL,
  UNIQUE KEY `user_id` (`user_id`,`permission_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;

-- Dumping data for table fitnessblackbook.user_permission: 2 rows
/*!40000 ALTER TABLE `user_permission` DISABLE KEYS */;
INSERT INTO `user_permission` (`user_id`, `permission_id`) VALUES
	(1, 1),
	(3, 1);
/*!40000 ALTER TABLE `user_permission` ENABLE KEYS */;
/*!40014 SET FOREIGN_KEY_CHECKS=1 */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
